<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@page import="com.xteam.ecsystem.utils.AppConfig"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<title>商品管理-商品列表</title>
		<jsp:include page="../../include/base.jsp"></jsp:include>
		<jsp:include page="../../include/common.jsp"></jsp:include>
		<script src="../../resource/kindeditor/kindeditor-min.js" type="text/javascript"></script> 
		<style type="text/css">
			html{overflow: hidden;}
			.goodsFormTab{width:100%;font-size:12px;padding-top:14px;}
			.attrListTab{padding-top:0;}
			.bottomDiv{width:100%; height:60px; text-align: center;line-height:60px;}
		</style>
		<script type="text/javascript">
			var __proImgPath = "<%=AppConfig.getProductImagePath() %>";
		</script>
	</head>
	<body>
		<form id="goodsForm" method="post" style="width:100%;height:100%;">
			<div class="mini-fit">
				<div id="goodsFormTab" class="mini-tabs" style="width:100%;height:100%;">
					<div title="商品基本信息">
						<table class="goodsFormTab" cellpadding="3" align="left" style="width:760px">
							<tr>
								<td align="right" width="80">商品名称：</td>
								<td>    
				                    <input name="bgiName" class="mini-textbox" onvalidation="validBgiName" width="260"/>
				                </td>
				                <td align="right">商品货号：</td>
								<td>    
				                    <input name="bgiGsn" class="mini-textbox" width="260"/>
				                </td>
							</tr>
							<tr>
								<td align="right">商品分类：</td>
								<td>    
				                    <!-- <input name="bgiGroup" id="bgiGroup_gft" class="mini-treeselect"  
					        			valueField="bggId" parentField="bggParent" textField="bggName" 
					        			url="%=path %>/getBggTreeSelect.do?type=add" 
					        			onvalidation="validBgiGroup" width="260" 
					        			onvaluechanged= "GoodsFormHandler.changeGoodsTypeCob"/> -->
					        			
					        		<input name="bgiGroup" id="bgiGroup_gft" class="mini-treeselect"  
					        			valueField="bggId" parentField="bggParent" textField="bggName" 
					        			url="<%=path %>/getBggTreeSelect.do?type=add" 
					        			onvalidation="validBgiGroup" width="260" 
					        			onvaluechanged= "GoodsFormHandler.changeBgaTab"/>
				                </td>
				                <td align="right">商品品牌：</td>
								<td>    
				                    <input class="mini-combobox" id="bgiBrand_gft" name="bgiBrand" 
							    		textField="bgbName" valueField="bgbId" required="true" 
							    		onvalidation="validBgiBrand" width="260" />
				                </td>
							</tr>
							<tr>
				                <td align="right">本店售价：</td>
								<td>    
				                    <input name="bgiPrice" class="mini-textbox" 
				                    	onvalidation="validBgiPrice" width="260"/>
				                </td>
				                <td align="right">市场售价：</td>
								<td>    
				                    <input name="bgiMarket" class="mini-textbox" 
				                    onvalidation="validBgiMarket" width="260"/>
				                </td>
							</tr>
							<tr>
				                <td align="right">商品规格：</td>
								<td>    
				                    <input name="bgiStandard" class="mini-textbox" width="260"/>
				                </td>
				                <td align="right">商品重量：</td>
								<td>    
				                    <input name="bgiWeight" class="mini-textbox" width="260"/>
				                </td>
							</tr>
							<tr>
				                <td align="right">商品库存：</td>
								<td>    
				                    <input name="bgiNumber" class="mini-textbox" 
				                    	onvalidation="validBgiNumber" width="260"/>
				                </td>
				                <td align="right">警告数量：</td>
								<td>    
				                    <input name="bgiWarn" class="mini-textbox" 
				                    	onvalidation="validBgiWarn" width="260"/>
				                </td>
							</tr>
							<tr>
								<td align="right">供货商家：</td>
								<td>    
				                    <input class="mini-combobox" id="bgiSupplier_gft" name="bgiSupplier" 
							    		textField="bsiName" valueField="bsiId" 
							    		onvalidation="validBgiSupplier" width="260" />
				                </td>
				                <td align="right">商品推荐：</td>
								<td>    
								    <div id="bgiBest_gft" name="bgiBest" class="mini-checkbox" 
	        			 				text="精品？" trueValue="1" falseValue="0" style="float:left;"></div>
	        			 			<div id="bgiBest_gft" name="bgiNew" class="mini-checkbox" 
	        			 				text="新品？" trueValue="1" falseValue="0" style="float:left;"></div>
	        			 			<div id="bgiBest_gft" name="bgiHot" class="mini-checkbox" 
	        			 				text="热销？" trueValue="1" falseValue="0" style="float:left;"></div>
	        			 			<div id="bgiBest_gft" name="bgiBuy" class="mini-checkbox" 
	        			 				text="团购？" trueValue="1" falseValue="0" style="float:left;"></div>
				                </td>
							</tr>
							<tr>
								<td align="right">上架时间：</td>
								<td>    
				                    <input id="bgiOn_gft" name="bgiOn" class="mini-datepicker"  
				                    	format="yyyy-MM-dd HH:mm" showTime="true" width="260"
				                    	onvalidation="validBgiOn"/>
				                </td>
				                <td align="right">下架时间：</td> 
								<td>    
				                    <input id="bgiOff_gft" name="bgiOff" class="mini-datepicker" 
				                    	format="yyyy-MM-dd HH:mm" showTime="true" width="260"
				                    	onvalidation="validBgiOff"/>
				                </td>
							</tr>
							<tr>
								<td align="right">商品排序：</td>
								<td>    
				                    <input name="bgiOrder" class="mini-textbox" 
				                    width="260" onvalidation="validBgiOrder"/>
				                </td>
				                <td align="right">关键词：</td>
								<td>    
				                    <input name="bgiKeyword" class="mini-textbox" width="260"/>
				                </td>
							</tr>
							<tr>
								<td align="right">商品状态：</td>
								<td>    
									<div id="bgiState" name="bgiState" class="mini-radiobuttonlist" 
						    		 	repeatItems="2" repeatLayout="table" repeatDirection="horizontal"  
						    		 	textField="text" valueField="value">
									</div> 
				                </td>
				                <td colspan="2">&nbsp;</td>
							</tr>
						</table>
					</div>
					<div title="商品特色信息">
						<table class="goodsFormTab" cellpadding="3" align="left">
							<tr>
								<td>
									<textarea id="bgiFeature_gft"
										style="width:100%;height:340px;"></textarea>
									<input id="bgiFeature" name="bgiFeature" 
										class="mini-textarea" visible="false"/>
								</td>
							</tr>
						</table>
					</div>
					<div title="商品详细描述">
						<table class="goodsFormTab" cellpadding="3" align="left">
							<tr>
								<td>
									<textarea id="bgiDetail_gft" 
										style="width:100%;height:340px;"></textarea>
									<input id="bgiDetail" name="bgiDetail" 
										class="mini-textarea" visible="false"/>
								</td>
							</tr>
						</table>
					</div>
					<div title="商品属性配置">
						<table class="goodsFormTab" cellpadding="3" align="left" style="height:10%;">
							<tr>
								<!-- 
								<td align="right" width="130">商品所属类型：</td>
								<td>
									 <input class="mini-combobox" id="btaGtype_gft" showNullItem="true"
						    			textField="bgtName" valueField="bgtId" width="359"
						    			onvaluechanged= "GoodsFormHandler.createGoodsAttrTab"/> 
						    		<a title="点击此处查看提示信息" href="javascript:showNotice('noticeBgt');">
						    			<img width="16" height="16" border="0" src="%=path %>/admin/resource/css/ico/lightbulb.gif"/>
						    		</a>
						    		<span id="bgtWarningId" style="font-size:12px; color:#999999;"></span>
								</td>
								-->
								<td colspan="2" align="center">
									<span id="bgtWarningId" style="font-size:12px; color:#DE2A2A;">
										请选择商品分类，以绘制商品属性列表！
									</span>
									<hr style="width:100%;border:0;border-bottom:1px dashed #D2D2D2;"/>
								</td>
							</tr>
						</table>
						<div style="height: 85%; width: 100%; overflow: auto !important; float: left;">
							<table id="typeAttrListTab" class="goodsFormTab attrListTab"
								 cellpadding="3" align="left"></table>
						</div>
					</div>
				</div>
			</div>
			<div class="bottomDiv">
				<input class="mini-button" text="保存" iconCls="icon-save" plain="false" 
   					onclick="GoodsFormHandler.saveGoodsInfo" id="saveBgiBtn"/>&nbsp;&nbsp;
   				<input class="mini-button" text="关闭" iconCls="icon-cancel" plain="false" 
   					onclick="GoodsFormHandler.closeMiniWin"/>
			</div>
	    </form>
	</body>
	<script src="handler/GoodsListFormValidation.js" type="text/javascript"></script>
	<script src="handler/GoodsListFormHandler.js" type="text/javascript"></script>
</html>
